﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="VoteSet.aspx.cs" Inherits="CMS_Admin_block_VoteSet" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<meta http-equiv="x-ua-compatible" content="ie=7" />

    <title>投票详细</title>
    <style>
        body
        {
            font-size: 13px;
        }
        .tb td
        {
            border: #fff solid 1px;
            font-size: 13px;
        }
    </style>

   

</head>
<body>
    <form id="form1" runat="server">
    <div style="border: solid 2px #b7ddf2; background: #ebf4fb; padding: 10px;">
        <table border="0" align="center" cellpadding="0" cellspacing="0" id="RightBox">
            <tr>
                <td valign="top">
                    <table width="600px" border="0" cellspacing="0" cellpadding="0">
                        <tr class="formcontenttitle">
                            <td width="150" height="27" class="bar">
                                <h3>
                                    投票明细</h3>
                            </td>
                            <td>
                            </td>
                        </tr>
                        <tr class="formcontentlist">
                            <td height="27" class="padleft5px" width="120px">
                                栏目名称：
                            </td>
                            <td class="padleft5px">
                                <asp:TextBox ID="txtName" runat="server" Width="200px"></asp:TextBox>
                                <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ErrorMessage="名称不得为空"
                                    ControlToValidate="txtName"></asp:RequiredFieldValidator>
                            </td>
                        </tr>
                        <tr class="formcontentlist">
                            <td height="27" class="padleft5px">
                                状态：
                            </td>
                            <td class="padleft5px">
                                <asp:RadioButtonList ID="rbStatus" runat="server">
                                    <asp:ListItem Value="1">正在发起的投票</asp:ListItem>
                                    <asp:ListItem Value="2" Selected="True">前台不显示</asp:ListItem>
                                    <asp:ListItem Value="0">投票作废(不显示)</asp:ListItem>
                                </asp:RadioButtonList>
                            </td>
                        </tr>
                        <tr>
                            <td colspan="2">
                                <asp:Button ID="add" runat="server" Text="发起新投票" OnClick="add_Click" OnClientClick="return confirm('确认？')" />
                                <asp:Button ID="save" runat="server" Text="修改" OnClick="save_Click" OnClientClick="return confirm('确认？')"
                                    Width="100px" />
                            </td>
                        </tr>
                    </table>
                </td>
            </tr>
        </table>
    </div>
    <br />
    <br />
    <div style="border: solid 2px #b7ddf2; background: #ebf4fb; padding: 10px;" runat="server"
        id="DivContent">
        <h3>
            投票明细-子项目</h3>
        <div>
            <asp:Button ID="NewOption" runat="server" Text="添加投票子项" OnClick="NewOption_Click" />
            <br />
            <br />
        </div>
        <table cellspacing="0" cellpadding="5" width="100%" border="0" class="tb" runat="server"
            id="addoption">
            <tr bgcolor="#cee6ff">
                <td style="width: 60%">
                    子项目名称：<asp:TextBox ID="option_name" runat="server" Width="50%"></asp:TextBox>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ErrorMessage="名称不得为空"
                        ControlToValidate="option_name"></asp:RequiredFieldValidator>
                </td>
                <td>
                    <asp:Button ID="option_add" runat="server" Text=" 添加 " OnClientClick="return confirm('确认？')"
                        OnClick="option_add_Click" />
                    <asp:Button ID="option_edit" runat="server" Text=" 修改 " OnClientClick="return confirm('确认？')"
                        OnClick="option_edit_Click" />
                    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                    <asp:Button ID="option_cancel" runat="server" Text=" 取消 " CausesValidation="False"
                        OnClick="option_cancel_Click" />
                </td>
            </tr>
            <tr>
                <td colspan="2">
                    <br />
                    <br />
                </td>
            </tr>
        </table>
        <asp:Repeater ID="RptList" runat="server" OnItemDataBound="RptList_ItemDataBound"
            OnItemCommand="RptList_ItemCommand">
            <HeaderTemplate>
                <table cellspacing="0" cellpadding="5" width="100%" border="0" class="tb">
                    <tr bgcolor="#cee6ff">
                        <td style="width: 30%">
                            操作
                        </td>
                        <td style="width: 30%">
                            编号
                        </td>
                        <td style="width: 30%">
                            名称
                        </td>
                    </tr>
            </HeaderTemplate>
            <ItemTemplate>
                <tr>
                    <td>
                        <asp:LinkButton ID="Del" runat="server" OnClientClick="return confirm('确认？')">删除</asp:LinkButton>
                        <asp:LinkButton ID="Edit" runat="server">修改</asp:LinkButton>
                    </td>
                    <td>
                        <%#DataBinder.Eval(Container.DataItem, "o_id")%>
                    </td>
                    
                    <td>
                        <%#DataBinder.Eval(Container.DataItem, "o_name")%>
                    </td>
                </tr>
            </ItemTemplate>
            <FooterTemplate>
                </table>
            </FooterTemplate>
        </asp:Repeater>
    </div>
    <div style="text-align:center">
    <br />
        <input id="this_close" type="button" value="关闭本窗口" onclick="opener.location.reload();window.close()"/>
    </div>
    </form>
</body>
</html>
